package cz.jj.tstr;

import androidx.appcompat.app.ActionBar;
import androidx.appcompat.app.AppCompatActivity;
import androidx.cardview.widget.CardView;
import androidx.constraintlayout.widget.ConstraintLayout;
import androidx.constraintlayout.widget.ConstraintSet;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;

import android.annotation.SuppressLint;
import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import androidx.appcompat.app.AppCompatActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;

import android.graphics.Color;
import android.os.Bundle;
import android.os.StrictMode;
import android.util.LayoutDirection;
import android.view.Gravity;
import android.view.View;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import android.widget.TextView;

import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.net.Socket;
import java.util.logging.Logger;

public class MainActivity extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        super.getActionBar().hide();
        StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitNetwork().build();
        StrictMode.setThreadPolicy(policy);
        RecyclerView rv=findViewById(R.id.rvc);
        LinearLayoutManager llm = new LinearLayoutManager(this);
        rv.setLayoutManager(llm);
        monitorEntry mon_ent=new monitorEntry();
        RVAdapter ra=new RVAdapter(mon_ent);
        rv.setAdapter(ra);
        rv.setOnTouchListener(new onSwipeTouchListener(this,this));



    }

    public void switchToAct(Class cls){
        Intent inte =new Intent(this,cls);
        inte.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
        Context cont=getApplicationContext();

        System.out.println("FUckyouuu!!!!!!");
        cont.startActivity(inte);



    }
}